﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using BusinessObjects.BO_GetObjects;
using DigiLib;
using System.Data;
public partial class Controls_ListCategoryNews : Base_Controls {
    protected void Page_Load(object sender, EventArgs e) {
        base.setField(Convert.ToInt32(this.Attributes["ID"]));
        if(!IsPostBack) {
            DataTable dt= BO_portal_articles.SelectLangByCategory(base.Cur_page, base.PSize, Convert.ToInt32(Request["CATEGORY_ID"]), "ARTICLES", base.Lang);
            if(dt.Rows.Count > 0) {
            } else {
                pagerContainer.InnerHtml = "Dữ liệu đang được cập nhật";
            }
            base.bindRepeater(rptSemilar, BO_portal_articles.SelectLangByCategory(base.Cur_page, base.PSize, Convert.ToInt32(Request["CATEGORY_ID"]), "ARTICLES", base.Lang), pagerContainer);
            ObjDT = BO_portal_categories.Search(Convert.ToInt32(Request["CATEGORY_ID"]));
            if(ObjDT.Rows.Count > 0) {
                title.InnerHtml = ObjDT.Rows[0]["FULL_CATEGORY_NAME"].ToString();
            } else {
                
            }
        }
    }

}